/*

function fuc1(callback, delay) {
	callback('aaa')
	return 'hello'
}


var callback = function(param) {
	console.log('callback ' + param)
}


var id = fuc1(() => callback(id), 1000);

console.log("id = "+ id)

*/

function intervalV1(callback, delay = 100) {
	let id = setTimeout(() => callback(id), delay);
 	console.log(`id = ${id}`)
}


function interval(callback, delay = 100) {
	let id = setTimeout(() => {
		console.log('setTimeout inner id = '+id)
		callback(id)
	}, delay);
 	console.log(`id = ${id}`)
}



interval(timeId => {
	console.log(`timeId = ${timeId}`)
})



